import request from '@/utils/request'

//登录接口
export function getRoleList(params) {
    return request({
        url: '/sys/role',
        params
    })
}
//新增角色接口
export function addRole(data) {
    return request({
        url: '/sys/role',
        method: 'post',
        data
    })
}
//更新角色接口
export function updataRole(data) {
    return request({
        url: `/sys/role/${data.id}`,
        method: 'put',
        data
    })
}
//删除角色接口
export function deleteRole(data) {
    return request({
        url: `/sys/role/${data.id}`,
        method: 'delete',
    })
}